﻿//-----------------------------------------------------------------------------------
// LoadTest Plugin Template version 1.0
//-----------------------------------------------------------------------------------
using System;
using Microsoft.VisualStudio.TestTools.LoadTesting;

namespace $rootnamespace$
{

    public class $safeitemname$ : ILoadTestPlugin
    {
        LoadTest m_loadTest;

        public void Initialize(LoadTest loadTest)
        {
            m_loadTest = loadTest;

            // Here's the complete list of events that are fired. You should delete events you are not using.
            // To see a list of events, type "m_loadTest." on a new line in the constructor.
            m_loadTest.LoadTestStarting += new EventHandler(LoadTest_LoadTestStarting);
            m_loadTest.LoadTestFinished += new EventHandler(LoadTest_LoadTestFinished);
            m_loadTest.LoadTestAborted += new EventHandler<LoadTestAbortedEventArgs>(LoadTest_LoadTestAborted);
            m_loadTest.LoadTestWarmupComplete += new EventHandler(LoadTest_LoadTestWarmupComplete);
            m_loadTest.TestStarting += new EventHandler<TestStartingEventArgs>(LoadTest_TestStarting);
            m_loadTest.TestFinished += new EventHandler<TestFinishedEventArgs>(LoadTest_TestFinished);
            m_loadTest.TestSelected += new EventHandler<TestSelectedEventArgs>(LoadTest_TestSelected);
            m_loadTest.ThresholdExceeded += new EventHandler<ThresholdExceededEventArgs>(LoadTest_ThresholdExceeded);
            m_loadTest.Heartbeat += new EventHandler<HeartbeatEventArgs>(LoadTest_Heartbeat);
        }

        void LoadTest_LoadTestStarting(object sender, EventArgs e) { }
        void LoadTest_LoadTestFinished(object sender, EventArgs e) { }
        void LoadTest_LoadTestAborted(object sender, LoadTestAbortedEventArgs e) { }
        void LoadTest_LoadTestWarmupComplete(object sender, EventArgs e) { }
        void LoadTest_TestFinished(object sender, TestFinishedEventArgs e) { }
        void LoadTest_TestSelected(object sender, TestSelectedEventArgs e) { }
        void LoadTest_TestStarting(object sender, TestStartingEventArgs e) { }
        void LoadTest_ThresholdExceeded(object sender, ThresholdExceededEventArgs e) { }
        void LoadTest_Heartbeat(object sender, HeartbeatEventArgs e) { }
    }
}

